Skip to content

Make deploy_predict_function work without Anaconda environments#194

Merged
dcrankshaw merged 6 commits intoucbrise:developfrom
nishadsingh1:deploy_func_wo_conda
Jun 3, 2017
Merged

Make deploy_predict_function work without Anaconda environments#194
dcrankshaw merged 6 commits intoucbrise:developfrom
nishadsingh1:deploy_func_wo_conda

Conversation

@nishadsingh1
Copy link

@nishadsingh1 nishadsingh1 commented Jun 2, 2017

Fixes #190

There's a ipython notebook with testcases. I think these could eventually be moved into python integration tests -- let me know what the best way to do this is would be (they require checking logs, waiting, etc).

We'd need to update this documentation when this PR goes through: ucbrise/clipper-website#2

@AmplabJenkins
Copy link

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Clipper-PRB/357/
Test FAILed.

@nishadsingh1 nishadsingh1 force-pushed the deploy_func_wo_conda branch from cdc5ea3 to 16806a1 Compare June 2, 2017 16:31
@AmplabJenkins
Copy link

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Clipper-PRB/360/
Test FAILed.

@nishadsingh1
Copy link
Author

Jenkins failures relate to formatting; I'm still running into the problem of the hanging formatting script. I'll figure it out since it'll be needed a lot, but the code itself should be readable for review regardless

@dcrankshaw dcrankshaw changed the title Can deploy predict func out of anaconda env Make deploy_predict_function work without Anaconda environments Jun 2, 2017
@nishadsingh1 nishadsingh1 force-pushed the deploy_func_wo_conda branch from 16806a1 to 03d7965 Compare June 2, 2017 16:57
@AmplabJenkins
Copy link

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Clipper-PRB/363/
Test PASSed.

Copy link
Contributor

@dcrankshaw dcrankshaw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is failing for me with an ImportError: No module named clipper_admin.pywrencloudpickle

Also, can you print out the import error here: https://github.com/ucbrise/clipper/blob/develop/containers/python/python_container.py#L121

Something like:

except ImportError as e:
    print("ImportError: %s" % e)
    sys.exit(IMPORT_ERROR_RETURN_CODE)


print("Supplied environment details")
else:
print("Anaconda environment was either not found or failed being exported")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rephrase to print("Anaconda environment was either not found or exporting the environment failed.")

print("Anaconda environment was either not found or failed being exported")
print(
"Your local environment details will not be supplied to and loaded in the container in which your model is deployed."
)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rephrase to:
"Your function will still be serialized deployed, but may fail due to missing dependencies. In this case, please re-run inside an Anaconda environment. See http://clipper.ai/documentation/python_model_deployment/ for more information."

dependency_check_returncode=$?

if [ $dependency_check_returncode -eq 0 ]; then
echo "Attempting to run Python container without installing without supplied dependencies."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rephrase/fix typo: "First attempting to run Python container without installing supplied dependencies."

fi
fi

echo "Encountered error not related to missing packages. Please refer to the above logs to diagnose."
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rephrase: "Encountered error not related to missing packages. Please refer to the container logs to diagnose."

@dcrankshaw
Copy link
Contributor

I did a bit of cleanup to make sure that this will work when the user installed clipper_admin via pip. It seems to be working on my computer. I want to wait for #187 to get merged and add tests for deploy_predict_function then this should be good to go.

@AmplabJenkins
Copy link

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Clipper-PRB/371/
Test FAILed.

@AmplabJenkins
Copy link

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Clipper-PRB/372/
Test FAILed.

@dcrankshaw
Copy link
Contributor

Note that these jenkins tests were intentionally killed by me.

@dcrankshaw dcrankshaw force-pushed the deploy_func_wo_conda branch from 29a44ee to c764965 Compare June 3, 2017 18:23
@AmplabJenkins
Copy link

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Clipper-PRB/376/
Test PASSed.

Copy link
Contributor

@dcrankshaw dcrankshaw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dcrankshaw dcrankshaw merged commit 818d8b4 into ucbrise:develop Jun 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants